import time
from selenium import webdriver

driver=webdriver.Chrome()
driver.get('http://www.bcbxhome.com/bcbxxy/home.php?mod=spacecp&ac=avatar')
driver.maximize_window()#设置窗体最大化
time.sleep(5)
driver.find_element_by_name('file').send_keys('D:/Pictures/1.png')
time.sleep(3)
time.sleep(4)